package tests.comunicacao;

import comunicacao.ConexaoBD;
import java.sql.SQLException;

import org.junit.*;

public class ConexaoBDTest {
	
	private static ConexaoBD c;
	
	@BeforeClass
	public static void globalInit() throws ClassNotFoundException, SQLException {
		c = new ConexaoBD();
	}
	@AfterClass
	public static void globalDeinit() {
		c = null;
	}
	
	@Test
	public void Conexao() throws SQLException {
		Assert.assertNotNull(c.getConexao());
		Assert.assertFalse(c.getConexao().isClosed());
		Assert.assertTrue(c.fecharConexao());
	}
}